package com.ecloud.openapi.security.convert;

import java.util.List;

import org.mapstruct.Mapper;
import org.mapstruct.factory.Mappers;

import com.ecloud.openapi.security.dto.BaseUserInfoDto;
import com.ecloud.openapi.security.po.BaseUserInfoPo;
import com.ecloud.openapi.security.vo.BaseUserInfoVo;

/**
 * BaseUserInfoConvert 模型转换
 *
 * @author LiuGangQiang Create in 2021/07/04
 */
@Mapper
public interface BaseUserInfoConvert {
    BaseUserInfoConvert INSTANCE = Mappers.getMapper(BaseUserInfoConvert.class);

    /**
     * {@link BaseUserInfoDto}对象 >> {@link BaseUserInfoPo}对象
     *
     * @author LiuGangQiang Create in 2021/07/04
     * @param dto 入参
     * @return {@link BaseUserInfoPo} 对象
     */
    BaseUserInfoPo dtoToPo(BaseUserInfoDto dto);

    /**
     * {@link BaseUserInfoDto}集合 >> {@link BaseUserInfoPo}集合
     *
     * @author LiuGangQiang Create in 2021/07/04
     * @param dtos 入参
     * @return {@link BaseUserInfoPo} 集合
     */
    List<BaseUserInfoPo> dtoToPo(List<BaseUserInfoDto> dtos);

    /**
     * {@link BaseUserInfoPo}对象 >> {@link BaseUserInfoVo}对象
     *
     * @author LiuGangQiang Create in 2021/07/04
     * @param dto 入参
     * @return {@link BaseUserInfoVo} 对象
     */
    BaseUserInfoVo poToVo(BaseUserInfoPo po);

    /**
     * {@link BaseUserInfoPo}集合 >> {@link BaseUserInfoVo}集合
     *
     * @author LiuGangQiang Create in 2021/07/04
     * @param dtos 入参
     * @return {@link BaseUserInfoVo} 集合
     */
    List<BaseUserInfoVo> poToVo(List<BaseUserInfoPo> pos);
}
